package com.poker.iuious.yhyhjs.jklimj;

import java.io.Serializable;
import java.util.Objects;

public class User implements Serializable {

    private String name;
    private String password;
    private String phone;
    private String email;
    private Integer id;
    private String loginId;
    private String loginTime;
    private Integer gender;
    private String relName;

    public User(String name, String password, String email) {
        this.name = name;
        this.password = password;
        this.email = email;
    }



    public User(String name, String phone, String email, Integer gender) {
        this.name = name;
        this.phone = phone;
        this.email = email;
        this.gender = gender;
    }

    public User(String name, String email, String phone, boolean flag) {
        this.name = name;
        this.email = email;
        this.phone = phone;
        System.out.println(flag);
    }

    public User(String name, String password, String phone, String email, String loginId, String loginTime,Integer gender,String relName) {
        this.name = name;
        this.password = password;
        this.phone = phone;
        this.email = email;
        this.loginId = loginId;
        this.loginTime = loginTime;
        this.gender = gender;
        this.relName = relName;
    }

    public User(String name,String phone, String email, Integer gender, String relName) {
        this.phone = phone;
        this.name = name;
        this.email = email;
        this.gender = gender;
        this.relName = relName;
    }

    public User() {
    }

    public User(String name, String password, String phone, String email, Integer id, String loginId, String loginTime, Integer gender, String relName) {
        this.name = name;
        this.password = password;
        this.phone = phone;
        this.email = email;
        this.id = id;
        this.loginId = loginId;
        this.loginTime = loginTime;
        this.gender = gender;
        this.relName = relName;
    }


    public User(String name, String password) {
        this.name = name;
        this.password = password;
    }

    public String getRelName() {
        return relName;
    }

    public void setRelName(String relName) {
        this.relName = relName;
    }

    public Integer getGender() {
        return gender;
    }

    public void setGender(Integer gender) {
        this.gender = gender;
    }

    public String getLoginTime() {
        return loginTime;
    }

    public void setLoginTime(String loginTime) {
        this.loginTime = loginTime;
    }

    public String getLoginId() {
        return loginId;
    }

    public void setLoginId(String loginId) {
        this.loginId = loginId;
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    @Override
    public String toString() {
        return "User{" +
                "name='" + name + '\'' +
                ", password='" + password + '\'' +
                ", phone='" + phone + '\'' +
                ", email='" + email + '\'' +
                ", id=" + id +
                ", loginId='" + loginId + '\'' +
                ", loginTime='" + loginTime + '\'' +
                ", gender=" + gender +
                ", relName='" + relName + '\'' +
                '}';
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        User user = (User) o;
        return Objects.equals(name, user.name) && Objects.equals(password, user.password) && Objects.equals(phone, user.phone) && Objects.equals(email, user.email) && Objects.equals(id, user.id) && Objects.equals(loginId, user.loginId) && Objects.equals(loginTime, user.loginTime) && Objects.equals(gender, user.gender) && Objects.equals(relName, user.relName);
    }

    @Override
    public int hashCode() {
        return Objects.hash(name, password, phone, email, id, loginId, loginTime, gender, relName);
    }
}
